#ifndef ContourAnalyzer_h__
#define ContourAnalyzer_h__

#pragma once
#include "ImageCenterline.h"
#include "AdjacencyGraphAnalyzer.h"

class CContourAnalyzer
{
public:
	CContourAnalyzer(void);
	~CContourAnalyzer(void);

public:
	bool		initFromFile(char* fileName1, char* fileName2);
	int			getWidth() {return m_nWidth;}
	int			getHeight(){return m_nHeight;}
	SPointI*	getValidImageData(int idx);
	int			getValidImageDataSize(int idx);
	void		printSelf(bool bPrintAll = false);
	void		computeDiameter(CAdjacencyGraphAnalyzer& cAdjAnalyzer);

private:
	bool	filterValidData();
	double	getImageData(int idx, int idy, int image=0);

private:
	int m_nWidth, m_nHeight;
	IplImage *m_imgGrey[IMAGE_PAIR_SIZE];

	MIPoints m_mValidPts[IMAGE_PAIR_SIZE];

};



#endif // ContourAnalyzer_h__
